package theOrbalEra.client.render.tileentity;

import org.lwjgl.opengl.GL11;

import cpw.mods.fml.client.FMLClientHandler;

import theOrbalEra.client.render.model.ModelStreetlight;
import theOrbalEra.common.block.TileEntityStreetLight;
import theOrbalEra.common.util.DefultValue;

import net.minecraft.block.Block;
import net.minecraft.client.gui.FontRenderer;
import net.minecraft.client.model.ModelSign;
import net.minecraft.client.renderer.tileentity.TileEntitySpecialRenderer;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.tileentity.TileEntitySign;

public class TileEntityRenderStreetLight extends TileEntitySpecialRenderer {

	
    private ModelStreetlight modelStreetlight = new ModelStreetlight();

    public void renderTileEntityStreetLightAt(TileEntityStreetLight par1TileEntityStreetLight, double par2, double par4, double par6, float par8)
    {
    	  this.bindTextureByName(DefultValue.Tile_StreetLight);
       
    	GL11.glEnable(GL11.GL_CULL_FACE);
    	  
    	GL11.glPushMatrix();
    	  GL11.glTranslatef((float)par2 + 0.5F, (float)par4 + 2.4F, (float)par6 + 0.5F);
    	  GL11.glRotatef(180.0F, 1.0F, 0.0F, 0.0F);
    	
        ((ModelStreetlight) this.modelStreetlight).renderThis(0.1F);
       
        
        GL11.glPopMatrix();
        GL11.glDisable(GL11.GL_CULL_FACE);
    }

    public void renderTileEntityAt(TileEntity par1TileEntity, double par2, double par4, double par6, float par8)
    {
        this.renderTileEntityStreetLightAt((TileEntityStreetLight)par1TileEntity, par2, par4, par6, par8);
    }

}
